﻿@using BathhouseService.Models.SqlModels;
@{
    ViewData["Title"] = "首页";
    Layout = "~/Areas/WX/Views/Shared/_Layout.cshtml";
}

<header class="hui-header">
    <a href="/Mobile/Account/Logout">
        <div id="hui-back"></div>
    </a>
    <h1>福利楼便民系统</h1>
</header>



<div class="hui-wrap">

    <div style="padding:10px;">
        <div class="hui-swipe" id="swipe">
            <div class="hui-swipe-items">
                @if (ViewBag.shufflingfigure != null)
                {
                    @foreach (var item in (List<ShufflingFigure>)ViewBag.shufflingfigure)
                    {
                        <div class="hui-swipe-item"><img height="200px;" src="/api/_file/GetFile/@item.PhotoId" /></div>
                    }
                }
                else
                {
                    <div class="hui-swipe-item"><img height="200px;" src="~/images/dqk.jpg" /></div>
                    <div class="hui-swipe-item"><img height="200px;" src="~/images/img1.jpg" /></div>
                    <div class="hui-swipe-item"><img height="200px;" src="~/images/img2.jpg" /></div>
                }
            </div>
        </div>
    </div>


    <div class="hui-wrap">
        <div class="hui-speed-dial">
            <ul>
                <li>
                    <a href="/WX/Home/ServicePayment">
                        <div class="hui-speed-dial-icons">
                            <img src="~/images/icon/付款.png" width="30%" />
                        </div>
                        <div class="hui-speed-dial-text">结账支付</div>
                    </a>

                </li>
                <li>
                    <a href="/WX/Home/PayBills">
                        <div class="hui-speed-dial-icons">
                            <img src="~/images/icon/账单.png" width="30%" />
                        </div>
                        <div class="hui-speed-dial-text">支付账单</div>
                    </a>
                </li>
                <li>
                    <a href="/WX/Home/MyService">
                        <div class="hui-speed-dial-icons">
                            <img src="~/images/icon/钱包.png" width="30%" />
                        </div>
                        <div class="hui-speed-dial-text">我的服务</div>
                    </a>
                </li>
            </ul>
        </div>

        <div class="hui-speed-dial" id="jfshwo">
            <ul>
                <li>
                    <a href="/WX/Home/WorkerServiceRecord">
                        <div class="hui-speed-dial-icons">
                            <img src="~/images/icon/服务记录.png" width="30%" />
                        </div>
                        <div class="hui-speed-dial-text">服务记录</div>
                    </a>
                </li>
                <li>
                    <a href="/WX/Home/PerformanceAppraisal">
                        <div class="hui-speed-dial-icons">
                            <img src="~/images/icon/绩效管理.png" width="30%" />
                        </div>
                        <div class="hui-speed-dial-text">绩效考核</div>
                    </a>

                </li>

            </ul>
        </div>

    </div>


    <div class="hui-common-title" style="margin-top:25px;">
        <div class="hui-common-title-line"></div>
        <div class="hui-common-title-txt">系统公告</div>
        <div class="hui-common-title-line"></div>
    </div>


    <div class="hui-list" style="margin-top:22px;">


        @foreach (var item in (List<Notice>)ViewBag.notice)
        {

            <a href="/WX/Home/NoticeDetailed/@item.ID">
                <div class="hui-list-icons">
                    <img src="~/HUI-master/img/spiker.png" />
                </div>
                <div class="hui-list-text">
                    @item.Title
                    <div class="hui-list-info">
                        查看 <span class="hui-icons hui-icons-right"></span>
                    </div>
                </div>
            </a>
        }
        </div>
    </div>

    <div class="hui-fooer-line"></div>
    <div id="hui-footer">
        <a href="/WX/Home/Index" id="nav-home">
            <div class="hui-footer-icons hui-icons-home"></div>
            <div class="hui-footer-text">首页</div>
        </a>
        <a href="/WX/Home/PayBills" id="nav-news">
            <div class="hui-footer-icons hui-icons-news"></div>
            <div class="hui-footer-text">账单</div>
        </a>
        <div style="width:20%; text-align:center;" class="hui-fl">
            <img src="~/images/jmlogo.jpg" height="44" onclick="hui.back();" />

        </div>
        <a href="/WX/Home/NoticeList" id="nav-forum">
            <div class="hui-footer-icons hui-icons-forum"></div>
            <div class="hui-footer-text">公告</div>
        </a>
        <a href="/WX/Home/PersonalPage" id="nav-my">
            <div class="hui-footer-icons hui-icons-my"></div>
            <div class="hui-footer-text">我的</div>
        </a>
    </div>

    <input type="hidden" value="@ViewBag.roleName" id="rolehiden" />
    @section Scripts{
        <script src="~/HUI-master/js/hui-swipe.js"></script>
        <script>
            var swipe = new huiSwpie('#swipe');
            swipe.autoPlay = true;
            swipe.run();
            var rolename = hui('#rolehiden').val();
            if (rolename != '师傅') {
                $('#jfshwo').hide();
            }
        </script>
    }
